/**
 * Created with IntelliJ IDEA.
 * User: duoba
 * Date: 16/3/1
 * Time: 下午6:01
 * To change this template use File | Settings | File Templates.
 */

package com.cake21.uitest.Case;

import com.cake21.uitest.Page.CakeRecommendPage;
import com.cake21.uitest.System.Core.Case;
import com.cake21.uitest.System.Core.Utils;

public class CakeRecommendTest extends Case {
    @Override
    protected void execute() {
        /*实例化产品推荐页面*/
        CakeRecommendPage crp = new CakeRecommendPage();
        /*滚动页面,载入所有图片*/
        Utils.GetReadyForFullPageScreenShot(crp.getDriver());
        /*判断页面内图片是否全部载入成功*/
        judge.is(crp.allImgLoaded(), "检查产品推荐页面所有图片", "图片(蛋糕)数量: " + crp.getGoodsCount());
        /*确认弹出框*/
        crp.confirmPopUpBtn();
        /*判断配送时间PopUp*/
        judge.is(crp.getShipTimePopUp() != "", "检查配送时间PopUp", crp.getShipTimePopUp());
    }
}
